package com.example.myapplication.entity;

import android.os.Parcel;
import android.os.Parcelable;

public class Hots implements Parcelable {


    /**
     * searchWord : 溯
     * score : 2733793
     * content : 慵懒歌曲，失眠的首选
     * source : 0
     * iconType : 1
     * iconUrl : https://p1.music.126.net/2zQ0d1ThZCX5Jtkvks9aOQ==/109951163968000522.png
     * url :
     * alg : alg_search_rec_hotquery_base_hotquery
     */

    private String searchWord;
    private int score;
    private String content;
    private int source;
    private int iconType;
    private String iconUrl;
    private String url;
    private String alg;

    public String getSearchWord() {
        return searchWord;
    }

    public void setSearchWord(String searchWord) {
        this.searchWord = searchWord;
    }

    public int getScore() {
        return score;
    }

    public void setScore(int score) {
        this.score = score;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public int getSource() {
        return source;
    }

    public void setSource(int source) {
        this.source = source;
    }

    public int getIconType() {
        return iconType;
    }

    public void setIconType(int iconType) {
        this.iconType = iconType;
    }

    public String getIconUrl() {
        return iconUrl;
    }

    public void setIconUrl(String iconUrl) {
        this.iconUrl = iconUrl;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getAlg() {
        return alg;
    }

    public void setAlg(String alg) {
        this.alg = alg;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.searchWord);
        dest.writeInt(this.score);
        dest.writeString(this.content);
        dest.writeInt(this.source);
        dest.writeInt(this.iconType);
        dest.writeString(this.iconUrl);
        dest.writeString(this.url);
        dest.writeString(this.alg);
    }

    public void readFromParcel(Parcel source) {
        this.searchWord = source.readString();
        this.score = source.readInt();
        this.content = source.readString();
        this.source = source.readInt();
        this.iconType = source.readInt();
        this.iconUrl = source.readString();
        this.url = source.readString();
        this.alg = source.readString();
    }

    public Hots() {
    }

    protected Hots(Parcel in) {
        this.searchWord = in.readString();
        this.score = in.readInt();
        this.content = in.readString();
        this.source = in.readInt();
        this.iconType = in.readInt();
        this.iconUrl = in.readString();
        this.url = in.readString();
        this.alg = in.readString();
    }

    public static final Parcelable.Creator<Hots> CREATOR = new Parcelable.Creator<Hots>() {
        @Override
        public Hots createFromParcel(Parcel source) {
            return new Hots(source);
        }

        @Override
        public Hots[] newArray(int size) {
            return new Hots[size];
        }
    };
}
